package com.econage.eccm.test.base.webdatasource.datasourcebuilder;

import javax.sql.DataSource;
import java.sql.SQLException;
import java.util.Properties;

public interface DataSourceBuilder {

    String PROP_TESTONBORROW = "testOnBorrow";
    String PROP_TESTWHILEIDLE = "testWhileIdle";

    String PROP_DEFAULTAUTOCOMMIT = "defaultAutoCommit";
    String PROP_DEFAULTTRANSACTIONISOLATION = "defaultTransactionIsolation";

    String PROP_DATASOURCE= "dataSource";
    String PROP_DATASOURCE_JNDI = "dataSourceJNDI";

    String PROP_DRIVERCLASSNAME = "driverClassName";
    String PROP_PASSWORD = "password";
    String PROP_URL = "url";
    String PROP_USERNAME = "username";

    DataSource build(Properties properties) throws SQLException;
}
